import config from "@/config"
import http from "@/utils/request"

export default {
	//自己的
	myMenus: {
		url: `${config.API_URL}/menu`,
		name: "获取我的菜单",
		post: async function(data={}){
			return await http.post(this.url,data);
		}
	},
	//全部
	list: {
		url: `${config.API_URL}/menu/all`,
		name: "获取菜单",
		post: async function(data={}){
			return await http.post(this.url,data);
		}
	},
	//角色的
	role: {
		url: `${config.API_URL}/menu/role`,
		name: "角色菜单",
		post: async function(data={}){
			return await http.post(this.url,data);
		}
	},
	ver: {
		url: `${config.API_URL}/version`,
		name: "获取最新版本号",
		get: async function(params){
			return await http.get(this.url, params);
		}
	}
}
